package liurong.driver.rmi;

import java.rmi.RemoteException;
import java.rmi.server.UnicastRemoteObject;
import java.util.concurrent.atomic.AtomicInteger;

public class TestServiceImpl extends UnicastRemoteObject implements TestService {

	private AtomicInteger flag = new AtomicInteger(0);

	protected TestServiceImpl() throws RemoteException {
		super();
	}

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	public String test1() throws RemoteException {
		System.out.println("第 " + flag.incrementAndGet() + " 次调用！");
		return "rmi success";
	}
}
